#include "widget.h"
#include "ui_widget.h"
#include <QtDebug>
Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);
//    ui->textEdit->toHtml(); // 支持html
//    ui->textEdit->toMarkdown(); // 支持 markdown
    ui->textEdit->setPlaceholderText("这是一个大输入框");

}

Widget::~Widget()
{
    delete ui;
}


void Widget::on_textEdit_textChanged()
{
    qDebug() << "Textchanged ";
}

void Widget::on_textEdit_selectionChanged()
{
    qDebug() << "selectionChanged ";
}

void Widget::on_textEdit_undoAvailable(bool b)
{
    qDebug() << "undoAvailable : " << b;
}

void Widget::on_textEdit_redoAvailable(bool b)
{
    qDebug() << "redoAvailable : " << b;
}

void Widget::on_textEdit_copyAvailable(bool b)
{
    qDebug() << "copyAvailable : " << b;
}

void Widget::on_textEdit_cursorPositionChanged()
{
    qDebug() << "cusorPositionChanged ";
}
